/*
 *  RGBADescriptor.h
 *  
 *
 *  Created by Peter on 23.02.12.
 *  Copyright 2012 __MyCompanyName__. All rights reserved.
 *
 */

#ifndef A_RGBA_DESCRIPTOR_H
#define A_RGBA_DESCRIPTOR_H

#include "DIDDescriptor.h"

/*
 * Describes the pixel format of an RGBA image. Version: 1 (MC 5.5).
 * This seems to encapsulate an OMFi RGBA descriptor.
 */
class RGBADescriptor : public DIDDescriptor
{
	
public:
	
	A_DECLARE_CLASS( 'RGBA', RGBADescriptor, DIDDescriptor );
	
	virtual void readFromStream( AStream& str, const AObjDoc& objd );
	virtual void dump( std::ostream& str ) const;
	
	UInt32   _pixelLayoutSize;    // 2
	UInt8*   _pixelLayout;        // OMFI:RGBA:PixelLayout: 4100
	UInt32   _pixelStructureSize; // 2
	UInt8*   _pixelStructure;     // OMFI:RGBA:PixelStructure: 0800
	UInt32   _paletteLayoutSize;  // 0
	// Palette layout might go here if size is non-null
	UInt32   _paletteStructureSize; // 0
	// Palette structure might go here if size is non-null
	UInt32   _paletteSize;        // 0
	// Palette data might go here if size is non-zero
};

#endif /*Inclusion Guard*/